﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace HU8.Web.FileExplorer.FileExplorer.SystemEnvironment
{
    public partial class Diagnosis : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        /// <summary>
        /// 系统测试显示
        /// </summary>
        /// <returns></returns>
        public string GetSystemVariables()
        {
            string result = "<ul>";
            result += string.Format("<li><label>用户域名：</label>{0}</li>", Environment.UserDomainName);
            result += string.Format("<li><label>用户名：</label>{0}</li>", Environment.UserName);
            result += string.Format("<li><label>系统文件夹：</label>{0}</li>", Environment.SystemDirectory);
            result += string.Format("<li><label>操作系统：</label>{0}</li>", Environment.OSVersion);
            result += string.Format("<li><label>64位线程：</label>{0}</li>", Environment.Is64BitProcess ? "是" : "否");
            result += string.Format("<li><label>64位操作系统：</label>{0}</li>", Environment.Is64BitOperatingSystem ? "是" : "否");
            result += string.Format("<li><label>所在路径：</label>{0}</li>", Environment.CurrentDirectory);
            result += "</ul>";
            return result;
        }
    }
}